package com.visizen.wisdomclass.server.client;

import com.visizen.wisdomclass.server.model.WcArticleContent;
import com.visizen.wisdomclass.server.model.WcArticleContentExample;
import java.util.List;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.DeleteProvider;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.InsertProvider;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Result;
import org.apache.ibatis.annotations.Results;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.SelectProvider;
import org.apache.ibatis.annotations.Update;
import org.apache.ibatis.annotations.UpdateProvider;
import org.apache.ibatis.type.JdbcType;

public interface WcArticleContentMapper {
    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_article_content
     *
     * @mbggenerated
     */
    @SelectProvider(type=WcArticleContentSqlProvider.class, method="countByExample")
    int countByExample(WcArticleContentExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_article_content
     *
     * @mbggenerated
     */
    @DeleteProvider(type=WcArticleContentSqlProvider.class, method="deleteByExample")
    int deleteByExample(WcArticleContentExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_article_content
     *
     * @mbggenerated
     */
    @Delete({
        "delete from wc_article_content",
        "where article_content_id = #{article_content_id,jdbcType=BIGINT}"
    })
    int deleteByPrimaryKey(Long article_content_id);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_article_content
     *
     * @mbggenerated
     */
    @Insert({
        "insert into wc_article_content (article_content_id, article_id, ",
        "image_attach_id, sort, ",
        "article_content)",
        "values (#{article_content_id,jdbcType=BIGINT}, #{article_id,jdbcType=BIGINT}, ",
        "#{image_attach_id,jdbcType=BIGINT}, #{sort,jdbcType=INTEGER}, ",
        "#{article_content,jdbcType=LONGVARCHAR})"
    })
    int insert(WcArticleContent record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_article_content
     *
     * @mbggenerated
     */
    @InsertProvider(type=WcArticleContentSqlProvider.class, method="insertSelective")
    int insertSelective(WcArticleContent record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_article_content
     *
     * @mbggenerated
     */
    @SelectProvider(type=WcArticleContentSqlProvider.class, method="selectByExampleWithBLOBs")
    @Results({
        @Result(column="article_content_id", property="article_content_id", jdbcType=JdbcType.BIGINT, id=true),
        @Result(column="article_id", property="article_id", jdbcType=JdbcType.BIGINT),
        @Result(column="image_attach_id", property="image_attach_id", jdbcType=JdbcType.BIGINT),
        @Result(column="sort", property="sort", jdbcType=JdbcType.INTEGER),
        @Result(column="article_content", property="article_content", jdbcType=JdbcType.LONGVARCHAR)
    })
    List<WcArticleContent> selectByExampleWithBLOBs(WcArticleContentExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_article_content
     *
     * @mbggenerated
     */
    @SelectProvider(type=WcArticleContentSqlProvider.class, method="selectByExample")
    @Results({
        @Result(column="article_content_id", property="article_content_id", jdbcType=JdbcType.BIGINT, id=true),
        @Result(column="article_id", property="article_id", jdbcType=JdbcType.BIGINT),
        @Result(column="image_attach_id", property="image_attach_id", jdbcType=JdbcType.BIGINT),
        @Result(column="sort", property="sort", jdbcType=JdbcType.INTEGER)
    })
    List<WcArticleContent> selectByExample(WcArticleContentExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_article_content
     *
     * @mbggenerated
     */
    @Select({
        "select",
        "article_content_id, article_id, image_attach_id, sort, article_content",
        "from wc_article_content",
        "where article_content_id = #{article_content_id,jdbcType=BIGINT}"
    })
    @Results({
        @Result(column="article_content_id", property="article_content_id", jdbcType=JdbcType.BIGINT, id=true),
        @Result(column="article_id", property="article_id", jdbcType=JdbcType.BIGINT),
        @Result(column="image_attach_id", property="image_attach_id", jdbcType=JdbcType.BIGINT),
        @Result(column="sort", property="sort", jdbcType=JdbcType.INTEGER),
        @Result(column="article_content", property="article_content", jdbcType=JdbcType.LONGVARCHAR)
    })
    WcArticleContent selectByPrimaryKey(Long article_content_id);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_article_content
     *
     * @mbggenerated
     */
    @UpdateProvider(type=WcArticleContentSqlProvider.class, method="updateByExampleSelective")
    int updateByExampleSelective(@Param("record") WcArticleContent record, @Param("example") WcArticleContentExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_article_content
     *
     * @mbggenerated
     */
    @UpdateProvider(type=WcArticleContentSqlProvider.class, method="updateByExampleWithBLOBs")
    int updateByExampleWithBLOBs(@Param("record") WcArticleContent record, @Param("example") WcArticleContentExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_article_content
     *
     * @mbggenerated
     */
    @UpdateProvider(type=WcArticleContentSqlProvider.class, method="updateByExample")
    int updateByExample(@Param("record") WcArticleContent record, @Param("example") WcArticleContentExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_article_content
     *
     * @mbggenerated
     */
    @UpdateProvider(type=WcArticleContentSqlProvider.class, method="updateByPrimaryKeySelective")
    int updateByPrimaryKeySelective(WcArticleContent record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_article_content
     *
     * @mbggenerated
     */
    @Update({
        "update wc_article_content",
        "set article_id = #{article_id,jdbcType=BIGINT},",
          "image_attach_id = #{image_attach_id,jdbcType=BIGINT},",
          "sort = #{sort,jdbcType=INTEGER},",
          "article_content = #{article_content,jdbcType=LONGVARCHAR}",
        "where article_content_id = #{article_content_id,jdbcType=BIGINT}"
    })
    int updateByPrimaryKeyWithBLOBs(WcArticleContent record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_article_content
     *
     * @mbggenerated
     */
    @Update({
        "update wc_article_content",
        "set article_id = #{article_id,jdbcType=BIGINT},",
          "image_attach_id = #{image_attach_id,jdbcType=BIGINT},",
          "sort = #{sort,jdbcType=INTEGER}",
        "where article_content_id = #{article_content_id,jdbcType=BIGINT}"
    })
    int updateByPrimaryKey(WcArticleContent record);
}